package com.jiezuo.auth.service;

import com.alibaba.fastjson.JSONArray;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.jiezuo.auth.entity.Depart;
import com.jiezuo.auth.entity.Role;
import com.jiezuo.auth.entity.User;
import com.jiezuo.common.vo.PageVo;
import com.jiezuo.common.vo.Result;
import java.util.List;
import java.util.Map;

public interface UserService extends IService<User> {

    IPage<User> findPage(Page page, User user);

    List<User> findList(User user);

    List<User> findDepartDownList(User user);

    //通过用户查询部门
    List<Depart> getDepartsByUserId(String user_id);

    //通过用户查询角色
    List<Role> getRolesByUserId(String user_id);

    List<User> findBusinessList();

    Result<IPage<User>> findUserList(PageVo pageVo, User user);

    List<User> findUserByDeparts(User user);

    List<Map<String, Object>> findSignList();

    void saveUser(User user);

    void updateUser(User user);

    Map<String, Object> getUserInfoByUserId(String id);

    IPage<User> findUserInfoByUserPage(Page page, User user);

    List<User> getUserByDepartsOrderByDepartIdAndUserId(String departs);

    User findBMFZRByDepartId(String depart_id);

//    void exportMenus(HttpServletResponse response, Map<String, Object> map) throws IOException;
//
//    void exportMenuDetails(HttpServletResponse response, Map<String, Object> map) throws IOException;
//
//    List<User> findBySysDict(String code);

    JSONArray getRoleDetailsByUserId(String userId);

//    IPage<User> findOnlineUserPage(Page page, User user);

    List<User> findChargeList(User user);

    List<User> getPersonsByGroups(User user);

    List<User> getStatisticUser(User user);

    List<User> getJiuzhouStatisticUser(User user);

//    List<User> getJiuzhouByRoleId();

    List<Role> findRolesByUserId(String user_id);

//    List<User> getDirectorByDepartId(String departId, String positionCode);

    List<User> findUserByRealName(User user);
}
